var e = getApp();

Component({
    properties: {
        data: {
            type: []
        },
        params: {
            type: null
        }
    },
    data: {
        language: "",
        datas: []
    },
    lifetimes: {
        attached: function() {
            var t = wx.getStorageSync("langIndex");
            this.setData({
                language: t.en
            }), this.properties.data.map(function(t) {
                if (!e._isTextEmpty(t.end_time)) {
                    if (t.nowTime = new Date().getTime() / 1e3, !e._isTextEmpty(t.start_time)) new Date(t.start_time).getTime() / 1e3 > t.nowTime ? (t.ishow = !1, 
                    t.getTime = new Date(t.start_time).getTime() / 1e3) : t.ishow = !0;
                    t.overTime = new Date(t.end_time).getTime() / 1e3;
                }
            });
            var a = this.properties.data;
            a.map(function(t) {
                e._isTextEmpty(t.min_price) && (t.min_price = ""), e._isTextEmpty(t.max_price) && (t.max_price = "");
            }), this.setData({
                datas: a
            });
        },
        moved: function() {},
        detached: function() {}
    },
    methods: {
        buy: function(e) {
            var t = e.target.dataset.item || e.currentTarget.dataset.item;
            wx.navigateTo({
                url: "/packageA/detail_v2/detail_v2?id=" + t.id + "&name=group"
            });
        }
    }
});